import { CardEditableParamsDefault, CardDataEditableParamsCommonDefault } from "@/views/card/js/data/cardDatas/card-datas-default.js";
import TooltipsData from "@/views/card/js/data/tooltipsData/tooltips-data.js";
const CARD_80 =  {
    title_sub: {
      ...CardEditableParamsDefault.TextareaNormal,
      label: '描述',
      placeholder: '请填入描述',
    },
    type_icon: {
      ...CardEditableParamsDefault.ImageNormal,
      label: '类型图标',
      res_type: 'String',  // Array : fileList, String : value
      placeholder: '请选择图标，png格式',
      limit: 1,
      size: 100,
      accept: '.png',
      tooltips: TooltipsData.image[0],
    },
    pic: {
      ...CardEditableParamsDefault.ImageNormal,
      label: '主图(比例 2:1)',
      res_type: 'String',  // Array : fileList, String : value
      placeholder: '请选择主图，jpg/jpeg/png格式',
      limit: 1,
      size: 500,
      accept: '.jpg, .jpeg, .png',
      tooltips: TooltipsData.image[9],
    },
    scheme: {
      ...CardEditableParamsDefault.InputNormal,
      label: '文章链接',
      placeholder: '请填入文章链接',
    },
    buttons: {
      ...CardEditableParamsDefault.Lists,
      label: '按钮',
      param_params: {
        type: {
          ...CardEditableParamsDefault.DropdownNormal,
          label: '按钮类型',
          placeholder: '请选择',
          valLists: [
            {
              name: '无',  // default
              value: '',
            },
            {
              name: '链接',
              value: 'link',
            },
            {
              name: '赞',
              value: 'like',
            },
          ],
        },
        name: {
          ...CardEditableParamsDefault.InputNormal,
          label: '按钮名称',
          placeholder: '请填入按钮名称',
        },
        pic: {
          ...CardEditableParamsDefault.ImageNormal,
          label: '按钮图标',
          res_type: 'String',  // Array : fileList, String : value
          placeholder: '请选择按钮图标，png格式',
          limit: 1,
          size: 100,
          accept: '.png',
          tooltips: TooltipsData.image[5],
        },
        pic_default: {
          ...CardEditableParamsDefault.ImageNormal,
          label: '按钮图标(同上)',
          res_type: 'String',  // Array : fileList, String : value
          placeholder: '请选择按钮图标，png格式',
          limit: 1,
          size: 100,
          accept: '.png',
          suffix: '_default',
          tooltips: TooltipsData.image[6],
        },
        show_loading: {},
        params: {
          ...CardEditableParamsDefault.Obj,
          label: '其他参数',
          param_params: {
            scheme: {
              ...CardEditableParamsDefault.InputNormal,
              label: '跳转链接',
              placeholder: '请填入跳转链接',
            },
            id: {
              ...CardEditableParamsDefault.InputNormal,
              label: '点赞Mid',
              placeholder: '请填入Mid',
            },
          },

          param_effect_parent: {
            effect_parent_keys: ['buttons', 'ARRAY_NUM', 'type'],
            effect_type: ['CHANGE_PARAMS'],
            effect_parent_val: '',
            effect_clear: {  // 有则 清除
              effect_clear_default_val: {},  // default
            },
            effect_obj_params: [  // 受 CHANGE_PARAMS 影响
              {
                effect_regular: new RegExp("^link$"),
                effect_new_obj_params: {
                  scheme: '',
                  hide_enable: 1,
                },
              },
              {
                effect_regular: new RegExp("^like$"),
                effect_new_obj_params: {
                  id: '',
                  type: 'status',
                },
              },
            ],
          },
        },
      },
    },
    ...CardDataEditableParamsCommonDefault,
  };
export default CARD_80;
